-
Notifications
You must be signed in to change notification settings - Fork 39
[MOB-12189] add-tests-to-iterableinappmanager #712
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
[MOB-12189] add-tests-to-iterableinappmanager #712
Conversation
…eneration in MockRNIterableAPI
Diff Coverage: Not applicable. There was no coverage data reported for the files in this diff. Total Coverage: This PR will increase coverage by 0.84%. File Coverage Changes
🛟 Help
This is from Qlty Cloud, the successor to Code Climate Quality. Learn more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM just some comments for future work
}; | ||
resolve(mockHtmlContent); | ||
}); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice mock
// WHEN calling removeMessage with invalid enum values | ||
// THEN it should not throw an error (values are passed through) | ||
expect(() => { | ||
manager.removeMessage(mockMessage, 999 as IterableInAppLocation, 888 as IterableInAppDeleteSource); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may want these errors to be handled in the future for invalid enum values.
expect(() => { | ||
manager.showMessage(mockMessage, 'true' as unknown as boolean); | ||
manager.setReadForMessage(mockMessage, 'false' as unknown as boolean); | ||
manager.setAutoDisplayPaused('true' as unknown as boolean); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similarly here
🔹 JIRA Ticket(s) if any
✏️ Description
Add tests to IterableInAppManager